<%@ include file="/common/taglibs.jsp"%>

<title><fmt:message key="customer.register.title"/></title>
<content tag="heading"><fmt:message key="customer.register.heading"/></content>

<html:form action="saveCustomer" method="post" styleId="customerForm" onsubmit="return validateCustomerForm(this)">
<ul>

<html:hidden property="customerId"/>

    <li>
        <carsite:label styleClass="desc" key="customerForm.username"/>
        <html:errors property="username"/>
        <html:text property="username" styleId="username" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.password"/>
        <html:errors property="password"/>
        <html:password property="password" styleId="password" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.confirmPassword"/>
        <html:errors property="confirmPassword"/>
        <html:password property="confirmPassword" styleId="confirmPassword" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.realName"/>
        <html:errors property="realName"/>
        <html:text property="realName" styleId="realName" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.email"/>
        <html:errors property="email"/>
        <html:text property="email" styleId="email" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.telNo"/>
        <html:errors property="telNo"/>
        <html:text property="telNo" styleId="telNo" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.mobileNo"/>
        <html:errors property="mobileNo"/>
        <html:text property="mobileNo" styleId="mobileNo" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.faxNo"/>
        <html:errors property="faxNo"/>
        <html:text property="faxNo" styleId="faxNo" styleClass="text medium"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.otherTelNo"/>
        <html:errors property="otherTelNo"/>
        <html:text property="otherTelNo" styleId="otherTelNo" styleClass="text medium"/>
    </li>
	
	<html:hidden property="status" value="1"/>
<%--
    <li>
        <carsite:label styleClass="desc" key="customerForm.status"/>
        <html:errors property="status"/>
        <html:checkbox property="status" styleId="status" styleClass="checkbox"/>
    </li>

    <li>
        <carsite:label styleClass="desc" key="customerForm.lastLoginTime"/>
        <html:errors property="lastLoginTime"/>
        <html:text property="lastLoginTime" styleId="lastLoginTime" styleClass="text medium"/>
    </li>
 --%>

    <li class="buttonBar bottom">
        <html:submit styleClass="button" property="method.save" onclick="bCancel=false">
            <fmt:message key="button.register"/>
        </html:submit>

		<%--
        <html:cancel styleClass="button" onclick="bCancel=true">
            <fmt:message key="button.cancel"/>
        </html:cancel>
		 --%>
    </li>
</ul>
</html:form>

<script type="text/javascript">
    Form.focusFirstElement($("customerForm"));
</script>
<%-- 
<html:javascript formName="customerForm" cdata="false" dynamicJavascript="true" staticJavascript="false"/>
--%>
<script type="text/javascript" src="<html:rewrite page="/scripts/validator.jsp"/>"></script>
